/* ==========================================================================
   BOOK APPOINTMENT PAGE (book appointment.css)
   Companion to services.css (shared header/nav/footer) — page-specific styles
   ========================================================================== */

.booking-section { background: #fff; }

.booking-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.booking-card {
  text-align: center;
  background: var(--color-bg-surface);
  border: 1px solid rgba(46, 111, 64, .14);
  border-radius: var(--radius-lg);
  padding: 2.5rem 2rem;
  box-shadow: var(--shadow-card);
  transition: all var(--transition-normal);
}

.booking-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }

.booking-step {
  width: 46px;
  height: 46px;
  margin: 0 auto 1.1rem;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--color-primary);
  color: #fff;
  font-family: var(--font-mono);
  font-size: 1.1rem;
  font-weight: 700;
}

.booking-card h3 { font-size: 1.25rem; color: var(--color-primary); margin-bottom: .6rem; }
.booking-card p { color: var(--color-text-muted); font-size: .97rem; line-height: 1.7; }
.booking-card a { color: var(--color-primary); font-weight: 600; }
.booking-card a:hover { color: var(--color-primary-dark); text-decoration: underline; }

.booking-note {
  max-width: 720px;
  margin: 2.5rem auto 0;
  text-align: center;
  background: var(--color-primary-subtle);
  border: 1px dashed rgba(46, 111, 64, .35);
  border-radius: var(--radius-md);
  padding: 1.5rem 2rem;
  color: var(--color-text-body);
}

/* "What to Expect" & "Before Your Appointment" — centred info cards
   (text layout inside the cards stays exactly as before) */
.booking-info-card {
  max-width: 760px;
  margin-left: auto;
  margin-right: auto;
  background: var(--color-bg-surface);
  border: 1px solid rgba(46, 111, 64, .14);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  padding: 2.25rem 2.5rem 2.5rem;
}

@media (max-width: 576px) {
  .booking-info-card { padding: 1.75rem 1.5rem 2rem; }
}

/* Schedule Your Visit — centred heading (CTA button removed) */
.booking-schedule .booking-subtitle { text-align: center; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  padding: .85rem 2rem;
  border-radius: var(--radius-full);
  font-size: .95rem;
  font-weight: 600;
  transition: all var(--transition-normal);
}

.btn-primary { background: var(--color-primary); color: #fff; box-shadow: 0 4px 14px rgba(46, 111, 64, .3); }
.btn-primary:hover { background: var(--color-primary-dark); transform: translateY(-2px); }

@media (max-width: 992px) {
  .booking-grid { grid-template-columns: 1fr; max-width: 520px; margin: 0 auto; }
}

/* ==========================================================================
   BOOKING PAGE INTRO / SUBSECTIONS
   ========================================================================== */

.booking-intro-copy {
  max-width: 760px;
  margin: 0 auto;
}

.booking-intro-copy p {
  color: var(--color-text-body);
  font-size: 1.02rem;
  line-height: 1.8;
  margin-bottom: 1.25rem;
}

/* Keep the vertical rhythm even: the last paragraph must not add extra space
   before the next card/section (uniform 3rem gaps everywhere) */
.booking-intro-copy p:last-child { margin-bottom: 0; }

.booking-subsection {
  margin-top: 3rem;
}

.booking-subtitle {
  font-size: 1.6rem;
  color: var(--color-primary);
  margin-bottom: 1rem;
}

.booking-lead {
  color: var(--color-text-body);
  font-size: 1rem;
  line-height: 1.7;
  margin-bottom: 1rem;
}

.booking-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.75rem;
}

.booking-list li {
  position: relative;
  padding-left: 1.6rem;
  color: var(--color-text-body);
  font-size: 1rem;
  line-height: 1.65;
}

.booking-list li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.45em;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--color-primary);
}

/* ==========================================================================
   BOOKING BRANCH CARDS (mirrors the index.html design exactly)
   ========================================================================== */

.branch-section-header {
  text-align: center;
  max-width: 720px;
  margin: 0 auto 3rem;
}

.branch-section-header .section-eyebrow {
  display: inline-block;
  margin-bottom: 0.75rem;
  font-family: var(--font-accent);
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--color-accent);
}

.branch-section-header .section-title {
  margin-bottom: 1rem;
  color: var(--color-primary);
  font-size: 2.5rem;
  line-height: 1.2;
}

.branch-section-header .section-description {
  margin: 0 auto;
  max-width: 650px;
  font-size: 1.05rem;
  line-height: 1.7;
  color: #66717a;
}

/* Inline link inside the section description (e.g. the first-time forms link) - highlighter style */
.branch-section-header .section-description a {
  color: #ffffff;
  font-weight: 800;
  background: var(--color-primary);
  padding: 0.12em 0.5em;
  border-radius: 6px;
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
}

.branch-section-header .section-description a:hover {
  color: #ffffff;
  background: var(--color-primary-dark);
}

.branch-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 2rem;
  align-items: stretch;
}

.branch-card {
  background: var(--color-primary);
  color: #ffffff;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  height: 100%;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.branch-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.25);
  border-color: rgba(255, 255, 255, 0.2);
}

.branch-image-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #eef2f4;
}

.branch-image {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.branch-card:hover .branch-image { transform: scale(1.03); }

.branch-content {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 2rem;
}

.branch-name {
  margin: 0 0 1.5rem;
  color: #ffffff;
  font-size: 1.9rem;
  line-height: 1.25;
}

.branch-detail { margin-bottom: 1.5rem; }
.branch-detail:last-of-type { margin-bottom: 2rem; }

.branch-detail h4 {
  margin: 0 0 0.65rem;
  font-family: var(--font-accent);
  font-size: 0.9rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: rgba(255, 255, 255, 0.85);
}

.branch-detail p {
  margin: 0 0 0.45rem;
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.9);
}

.branch-detail p:last-child { margin-bottom: 0; }

.branch-detail strong { font-weight: 700; color: #ffffff; }

/* Contact rows — icon + value (phone / email / WhatsApp / address) */
.branch-contact-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}

.branch-contact-row {
  display: flex;
  align-items: flex-start;
  gap: 0.7rem;
  font-size: 1rem;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.9);
}

.branch-contact-icon {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  margin-top: 0.22rem;
  color: #ffffff;
}

/* WhatsApp brand green so the click-to-chat row is instantly recognisable */
.branch-contact-icon--whatsapp { color: #25d366; }

.branch-detail a {
  color: #ffffff;
  text-decoration: underline;
  transition: color var(--transition-fast);
}

.branch-detail a:hover { color: var(--color-accent); }

/* Booking button — blue to match index.html's btn-primary */
.branch-booking-btn {
  margin-top: auto;
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 50px;
  padding: 0.8rem 1.5rem;
  text-decoration: none;
  background: var(--color-secondary);
  color: #ffffff;
  border-radius: var(--radius-md);
  box-shadow: 0 4px 14px rgba(31, 77, 141, 0.3);
  transition: transform var(--transition-fast), background var(--transition-fast), box-shadow var(--transition-fast);
}

.branch-booking-btn:hover {
  background: var(--color-secondary-dark);
  transform: translateY(-2px);
}

.branch-map-wrapper {
  position: relative;
  width: 100%;
  height: 240px;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  background: #eef2f4;
}

.branch-map-wrapper iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
}

.map-overlay-btn {
  position: absolute;
  bottom: 1rem;
  right: 1rem;
  background: rgba(46, 111, 64, 0.95);
  color: #ffffff;
  padding: 0.55rem 1.1rem;
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  font-weight: 600;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-fast);
}

.map-overlay-btn:hover { background: var(--color-primary-dark); }

/* ==========================================================================
   TABLET & MOBILE (mirrors index.html)
   ========================================================================== */

@media (max-width: 900px) {
  .branch-grid { gap: 1.5rem; }
  .branch-content { padding: 1.75rem; }
  .branch-name { font-size: 1.7rem; }
}

@media (max-width: 768px) {
  .branch-section-header { margin-bottom: 2rem; }
  .branch-section-header .section-title { font-size: 2rem; }
  .branch-section-header .section-description { font-size: 1rem; }
  .branch-grid { grid-template-columns: 1fr; gap: 1.5rem; }
  .branch-content { padding: 1.5rem; }
  .branch-name { font-size: 1.6rem; }
  .branch-booking-btn { width: 100%; }
  .branch-map-wrapper { height: 210px; }
  .branch-map-wrapper .map-overlay-btn { bottom: 0.75rem; right: 0.75rem; }
}

@media (max-width: 480px) {
  .branch-image-wrapper { aspect-ratio: 4 / 3; }
  .branch-content { padding: 1.25rem; }
  .branch-detail p { font-size: 0.95rem; }
  .branch-contact-row { font-size: 0.95rem; }
}

/* Appointment Types — 2-column card grid */
.appointment-types-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
}

@media (max-width: 992px) {
  .appointment-types-grid { grid-template-columns: 1fr; }
}

/* ==========================================================================
   FIRST-TIME PATIENT FORMS (PDF view/download cards)
   ========================================================================== */

.patient-forms-section { background: #fff; }

/* Step-by-step guide (download → fill in → send) — reuses .booking-card & .booking-step */
.patient-forms-steps {
  list-style: none;
  margin: 0 auto 3rem;
  padding: 0;
  max-width: 1000px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

@media (max-width: 992px) {
  .patient-forms-steps { grid-template-columns: 1fr; max-width: 520px; }
}

.patient-forms-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
  max-width: 1000px;
  margin: 0 auto 2rem;
}

.patient-form-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  background: var(--color-bg-surface);
  border: 1px solid rgba(46, 111, 64, .14);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  padding: 2.5rem 2rem;
  transition: all var(--transition-normal);
}

.patient-form-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }

.patient-form-icon {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--color-primary-subtle);
  color: var(--color-primary);
  display: grid;
  place-items: center;
  margin-bottom: 1.25rem;
}

.patient-form-name {
  font-size: 1.45rem;
  color: var(--color-text-heading);
  margin-bottom: .6rem;
}

.patient-form-desc {
  color: var(--color-text-muted);
  font-size: .97rem;
  line-height: 1.7;
  margin-bottom: 1.25rem;
  max-width: 40ch;
}

.patient-form-meta {
  list-style: none;
  margin: 0 0 1.75rem;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: .45rem;
}

.patient-form-meta li {
  position: relative;
  padding-left: 1.4rem;
  color: var(--color-text-body);
  font-size: .92rem;
  text-align: left;
}

.patient-form-meta li::before {
  content: '';
  position: absolute;
  left: 0;
  top: .28em;
  width: .95rem;
  height: .95rem;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%232e6f40' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 13l4 4L19 7'/%3E%3C/svg%3E") center / contain no-repeat;
}

/* Green View / Download buttons */
.patient-form-actions {
  margin-top: auto;
  display: flex;
  gap: .8rem;
  width: 100%;
}

.btn-green {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .45rem;
  min-height: 50px;
  padding: .8rem 1.25rem;
  border: 0;
  border-radius: var(--radius-full);
  background: var(--color-primary);
  color: #fff;
  font-size: .95rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  box-shadow: 0 4px 14px rgba(46, 111, 64, .3);
  transition: all var(--transition-fast);
}

.btn-green:hover {
  background: var(--color-primary-dark);
  transform: translateY(-2px);
  color: #fff;
}

.btn-green svg { flex-shrink: 0; }

/* "Completed your forms?" upload strip */
.upload-card {
  max-width: 1000px;
  margin: 0 auto 2.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  flex-wrap: wrap;
  background: var(--color-primary-subtle);
  border: 1px dashed rgba(46, 111, 64, .4);
  border-radius: var(--radius-lg);
  padding: 1.75rem 2rem;
}

.upload-card-copy { flex: 1 1 320px; }

.upload-card-copy h3 {
  font-size: 1.3rem;
  color: var(--color-text-heading);
  margin-bottom: .35rem;
}

.upload-card-copy p {
  margin: 0;
  color: var(--color-text-body);
  font-size: .95rem;
  line-height: 1.7;
}

/* WhatsApp / Email send buttons on the "Completed your forms?" strip */
.upload-card-actions {
  display: flex;
  gap: .8rem;
  flex-wrap: wrap;
}

.upload-card .btn-whatsapp,
.upload-card .btn-mail { flex: 0 0 auto; }

@media (max-width: 768px) {
  .upload-card-actions { width: 100%; }
  .upload-card-actions .btn { flex: 1 1 100%; }
}

.patient-forms-note {
  max-width: 720px;
  margin: 0 auto;
  text-align: center;
  background: var(--color-bg-surface);
  border: 1px solid rgba(46, 111, 64, .14);
  border-radius: var(--radius-md);
  padding: 1.25rem 1.75rem;
  color: var(--color-text-muted);
  font-size: .92rem;
  line-height: 1.7;
}

/* ==========================================================================
   UPLOAD POP-UP MODAL (completed forms)
   ========================================================================== */

body.modal-open { overflow: hidden; }

.form-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
  background: rgba(23, 45, 31, .55);
  backdrop-filter: blur(4px);
  opacity: 0;
  transition: opacity var(--transition-fast);
}

.form-modal-overlay.visible { opacity: 1; }
.form-modal-overlay[hidden] { display: none; }

.form-modal {
  width: min(620px, 100%);
  max-height: min(90vh, 820px);
  background: #fff;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transform: translateY(18px) scale(.985);
  transition: transform var(--transition-fast);
}

.form-modal-overlay.visible .form-modal { transform: none; }

.form-modal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.4rem 1.75rem;
  background: var(--color-primary);
  color: #fff;
}

.form-modal-header h3 {
  font-size: 1.35rem;
  color: #fff;
  margin-bottom: .2rem;
}

.form-modal-header p {
  margin: 0;
  color: rgba(255, 255, 255, .85);
  font-size: .85rem;
}

.form-modal-close {
  flex-shrink: 0;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 0;
  background: rgba(255, 255, 255, .14);
  color: #fff;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: background var(--transition-fast);
}

.form-modal-close:hover { background: rgba(255, 255, 255, .28); }

.form-modal-body {
  overflow-y: auto;
  padding: 1.75rem;
  background: #fff;
}

.form-modal-footer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: .9rem;
  padding: 1.05rem 1.75rem;
  border-top: 1px solid rgba(46, 111, 64, .12);
  background: var(--color-bg-surface);
}

.form-modal-footer[hidden] { display: none; }

.form-privacy-note {
  margin: 0;
  font-size: .82rem;
  color: var(--color-text-muted);
}

.form-modal-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

/* --- Upload form fields --- */

.upload-form {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: .4rem;
}

.form-group label {
  font-size: .88rem;
  font-weight: 600;
  color: var(--color-text-body);
}

.form-hint {
  font-size: .78rem;
  color: var(--color-text-muted);
  font-weight: 400;
}

.required-mark { color: var(--color-accent); }

.upload-form input[type="text"],
.upload-form input[type="email"],
.upload-form select {
  width: 100%;
  padding: .72rem .85rem;
  border: 1px solid #c9d6cc;
  border-radius: var(--radius-sm);
  background: #fff;
  color: var(--color-text-heading);
  font: inherit;
  font-size: .95rem;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.upload-form input:focus,
.upload-form select:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(46, 111, 64, .14);
}

/* Drop zone */
.upload-dropzone {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .3rem;
  padding: 1.75rem 1.25rem;
  border: 2px dashed rgba(46, 111, 64, .35);
  border-radius: var(--radius-md);
  background: var(--color-bg-surface);
  color: var(--color-primary);
  cursor: pointer;
  text-align: center;
  transition: border-color var(--transition-fast), background var(--transition-fast);
}

.upload-dropzone:hover,
.upload-dropzone.dragover {
  border-color: var(--color-primary);
  background: var(--color-primary-subtle);
}

.upload-dropzone.has-files {
  border-style: solid;
  border-color: var(--color-primary);
}

.upload-dropzone-title {
  font-weight: 600;
  font-size: .95rem;
  color: var(--color-text-body);
}

/* Visually hidden but still focusable/validatable file input */
.upload-input {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.upload-file-list {
  list-style: none;
  margin: 0;
  padding: .75rem 1rem;
  background: var(--color-bg-surface);
  border: 1px solid rgba(46, 111, 64, .18);
  border-radius: var(--radius-sm);
  font-size: .88rem;
  color: var(--color-text-body);
  display: flex;
  flex-direction: column;
  gap: .3rem;
}

.upload-file-total {
  font-weight: 700;
  color: var(--color-primary);
  border-top: 1px dashed rgba(46, 111, 64, .25);
  padding-top: .3rem;
}

/* Honeypot — visually removed but present for bots */
.hp-field {
  position: absolute !important;
  left: -10000px !important;
  top: auto !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* Hidden iframe used to post the file upload natively (delivers attachments) */
.fs-upload-frame {
  position: absolute;
  width: 1px;
  height: 1px;
  left: -10000px;
  top: auto;
  border: 0;
  overflow: hidden;
}
.fs-upload-frame[hidden] { display: none !important; }

/* Success panel — list of files sent */
.upload-sent-section {
  width: 100%;
  max-width: 380px;
  text-align: left;
  background: var(--color-primary-subtle);
  border: 1px solid rgba(46, 111, 64, .25);
  border-radius: var(--radius-sm);
  padding: .7rem .9rem;
  font-size: .9rem;
  color: var(--color-text-muted);
}

.upload-sent-list {
  margin: .4rem 0 0;
  padding-left: 1.1rem;
  display: flex;
  flex-direction: column;
  gap: .25rem;
  word-break: break-word;
}

/* Error / warning / success states */
.form-modal [hidden] { display: none !important; }

.form-alert {
  background: var(--color-accent-subtle);
  border: 1px solid rgba(240, 77, 35, .35);
  color: #8a2a10;
  border-radius: var(--radius-sm);
  padding: .95rem 1.1rem;
  font-size: .92rem;
  margin-bottom: 1.25rem;
}

.form-alert a { color: inherit; font-weight: 600; }

.form-alert--warning {
  background: #fdf6e3;
  border-color: rgba(196, 145, 22, .4);
  color: #7a5a10;
}

.upload-link-list {
  margin: .6rem 0 0;
  padding-left: 1.1rem;
  display: flex;
  flex-direction: column;
  gap: .3rem;
  word-break: break-all;
}

.form-success-panel {
  text-align: center;
  padding: 2.5rem 1rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .75rem;
}

.form-status-icon {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--color-primary-subtle);
  color: var(--color-primary);
  display: grid;
  place-items: center;
}

.form-success-panel h4 {
  font-size: 1.4rem;
  color: var(--color-text-heading);
  margin: 0;
}

.form-success-panel p {
  margin: 0;
  color: var(--color-text-muted);
  max-width: 46ch;
}

.form-status-actions {
  display: flex;
  gap: .9rem;
  flex-wrap: wrap;
  justify-content: center;
  margin-top: .75rem;
}

.btn-outline {
  border: 1.5px solid rgba(46, 111, 64, .4);
  color: var(--color-primary);
  background: transparent;
}

.btn-outline:hover { background: var(--color-primary-subtle); transform: none; }

.btn-small { padding: .55rem 1.1rem; font-size: .85rem; min-height: 0; }

.btn-whatsapp {
  background: #25d366;
  color: #fff;
  text-decoration: none;
  box-shadow: 0 3px 10px rgba(37, 211, 102, .3);
}

.btn-whatsapp:hover { background: #1fb857; color: #fff; transform: translateY(-2px); }

.btn-mail {
  background: var(--color-secondary);
  color: #fff;
  text-decoration: none;
}

.btn-mail:hover { background: var(--color-secondary-dark); color: #fff; transform: translateY(-2px); }

.form-alert--info {
  background: #eef4fb;
  border: 1px solid rgba(31, 77, 141, .3);
  color: #1f4d8d;
  border-radius: var(--radius-sm);
  padding: .95rem 1.1rem;
  font-size: .9rem;
  margin-bottom: 1.25rem;
}

.form-alert--info strong { display: block; margin-bottom: .2rem; }

.form-fallback-panel {
  background: var(--color-bg-surface);
  border: 1px solid rgba(46, 111, 64, .3);
  border-radius: var(--radius-sm);
  padding: 1.05rem 1.15rem;
  font-size: .92rem;
  color: var(--color-text-body);
  margin-bottom: 1.25rem;
}

.form-fallback-panel strong { color: var(--color-text-heading); }

.upload-fallback-msg { margin: .4rem 0 0; }

.form-fallback-actions {
  display: flex;
  gap: .6rem;
  flex-wrap: wrap;
  margin-top: .85rem;
}

.upload-dropzone.dropzone-error {
  border-color: rgba(240, 77, 35, .6);
  background: var(--color-accent-subtle);
}

/* ==========================================================================
   PATIENT FORMS & UPLOAD MODAL — TABLET & MOBILE
   ========================================================================== */

@media (max-width: 768px) {
  .patient-forms-grid { grid-template-columns: 1fr; max-width: 480px; }

  .patient-form-actions { flex-direction: column; }

  .upload-card {
    flex-direction: column;
    align-items: stretch;
    text-align: center;
  }

  .form-modal-overlay { padding: 0; align-items: stretch; }

  .form-modal {
    max-height: 100vh;
    height: 100%;
    border-radius: 0;
  }

  .form-modal-body { padding: 1.25rem; }

  .form-modal-footer {
    flex-direction: column;
    align-items: stretch;
    text-align: center;
  }

  .form-modal-actions { justify-content: center; }

  .form-modal-actions .btn { width: 100%; }
}

/* ==========================================================================
   FOOTER — SHARED WITH services.css (page-specific override file)
   These styles mirror the footer system in services.css so the footer
   renders correctly even if this stylesheet is loaded independently.
   ========================================================================== */

.site-footer {
  background: var(--color-primary-dark);
  color: #fff;
  border-top: 1px solid rgba(255, 255, 255, .15);
  padding: 4.5rem 0 2.5rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.5fr;
  gap: 3rem;
  margin-bottom: 3.5rem;
}

.footer-brand { display: flex; flex-direction: column; gap: 1rem; }

.site-footer .brand-logo { text-decoration: none; }

.site-footer .footer-brand-name {
  color: #fff;
  text-shadow: none;
  white-space: nowrap;
}

.footer-desc {
  color: rgba(255, 255, 255, .82);
  font-size: .95rem;
  line-height: 1.65;
  max-width: 320px;
}

/* Social media icons (footer brand column) */
.footer-social {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .5rem;
  margin-top: .25rem;
}

.footer-social-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  color: #fff;
  background: rgba(255, 255, 255, .12);
  transition: all var(--transition-fast);
}

.footer-social-link svg {
  width: 17px;
  height: 17px;
  fill: currentColor;
  display: block;
}

.footer-social-link:hover {
  background: #fff;
  color: var(--color-primary);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, .25);
}

.footer-heading {
  font-size: 1.2rem;
  margin-bottom: 1.25rem;
  color: #fff;
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: .75rem;
}

.footer-links a {
  color: rgba(255, 255, 255, .82);
  font-size: .95rem;
}

.footer-links a:hover {
  color: #fff;
  text-decoration: underline;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, .12);
  padding-top: 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  font-size: .9rem;
  color: rgba(255, 255, 255, .75);
}

/* --------------------------------------------------------------------------
   FOOTER RESPONSIVE — TABLET & MOBILE GRID COLLAPSE
   -------------------------------------------------------------------------- */
@media (max-width: 992px) {
  .footer-grid {
    grid-template-columns: 2fr 1fr 1fr;
    gap: 2.5rem;
  }

  .footer-brand { grid-column: 1 / -1; }
}

@media (max-width: 768px) {
  :root { --container-max-width: 540px; }

  .container { padding: 0 1.25rem; }

  .footer-grid {
    grid-template-columns: 2fr 1fr 1fr;
    gap: 2.5rem;
  }

  .footer-brand { grid-column: 1 / -1; }

  .footer-social { gap: 0.45rem; }
  .footer-social-link {
    width: 32px;
    height: 32px;
    max-width: 32px;
    max-height: 32px;
  }
  .footer-social-link svg { width: 15px; height: 15px; }
}

/* Small phones */
@media (max-width: 576px) {
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .footer-brand { grid-column: auto; }

  .footer-bottom {
    flex-direction: column;
    text-align: center;
    gap: 1rem;
    padding-top: 1.5rem;
  }

  .footer-social { gap: 0.4rem; }
  .footer-social-link {
    width: 30px;
    height: 30px;
    max-width: 30px;
    max-height: 30px;
  }
  .footer-social-link svg { width: 14px; height: 14px; }
}
